home *** CD-ROM | disk | FTP | other *** search
/ Aminet 4 / Aminet 4 - November 1994.iso / aminet / comm / uucp / wcnews_1_0_30.lha / man / expire.man < prev    next >
Text File  |  1994-01-04  |  14KB  |  331 lines

  1.  
  2.  
  3.  
  4. EXPIRE(8)                                               EXPIRE(8)
  5.  
  6.  
  7. ›1mNAME›22m
  8.        expire, doexpire - expire old news
  9.        mkhistory - rebuild news history file
  10.        upact - update news active file
  11.        recovact - partially recover news active file
  12.  
  13. ›1mSYNOPSIS›22m
  14.        ›1m/usr/lib/newsbin/expire/expire›22m  [ ›1m-a›22m archdir ] [ ›1m-p›22m ] [ ›1m-s›22m
  15.        ] [ ›1m-F›22m c ] [ ›1m-c›22m ] [ ›1m-n›22m nnnnn ] [ ›1m-t›22m ] [ ›1m-l›22m ] [ ›1m-v›22m ] [ ›1m-d›22m ]
  16.        [ ›1m-r›22m ] [ ›1m-g›22m ] [ ›1m-h›22m ] [ controlfile ]
  17.        ›1m/usr/lib/newsbin/expire/doexpire›22m expireoptions
  18.        ›1m/usr/lib/newsbin/expire/mkhistory›22m
  19.        ›1m/usr/lib/newsbin/expire/upact›22m
  20.        ›1m/usr/lib/newsbin/expire/recovact›22m
  21.  
  22. ›1mDESCRIPTION›22m
  23.        ›4mExpire›24m expires old news, removing it from the current­news
  24.        directories and (if asked to) archiving it elsewhere.   It
  25.        updates  news's ›4mhistory›24m file to match.  ›4mExpire›24m should nor­
  26.        mally be run nightly, typically  by  using  ›4mdoexpire›24m  (see
  27.        below).
  28.  
  29.        ›4mExpire›24m's  operations  are  controlled  by  a  control file
  30.        (which can be named or supplied on standard input),  which
  31.        is  not optional­­there is no default behavior.  Each line
  32.        of the control file (except  for  empty  lines  and  lines
  33.        starting  with  `#',  which  are ignored) should have four
  34.        white­space­separated fields, as follows.
  35.  
  36.        The first field is one or more  newsgroups,  separated  by
  37.        commas (no spaces!); partial specifications are acceptable
  38.        (e.g. `comp' specifies all groups with that prefix).
  39.  
  40.        The second field is one letter, `m', `u', or `x', specify­
  41.        ing  that  the line applies only to moderated groups, only
  42.        to unmoderated groups, or to both, respectively.
  43.  
  44.        The third field specifies the expiry period in days.   The
  45.        most  general  form  is three numbers separated by dashes.
  46.        The units are days; decimal fractions are permitted.   The
  47.        first  number  gives  the  retention period: how long must
  48.        pass after an article's arrival before it is  a  candidate
  49.        for  expiry.   The  third number gives the purge date: how
  50.        long must pass after arrival before the  article  will  be
  51.        expired  unconditionally.   The  middle  number  gives the
  52.        default expiry date: how long after an  article's  arrival
  53.        it  is expired by default.  An explicit expiry date in the
  54.        article will override the default expiry date but not  the
  55.        retention period or the purge date.  If the field contains
  56.        only two numbers with a dash separating them,  the  reten­
  57.        tion  period  defaults to 0.  If the field contains only a
  58.        number, the retention period defaults to 0 and  the  purge
  59.        date defaults to `never'.  (But see below.)
  60.  
  61.  
  62.  
  63.  
  64.                            28 Oct 1990                          1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. EXPIRE(8)                                               EXPIRE(8)
  71.  
  72.  
  73.        The  fourth  field is an archiving directory, or `@' which
  74.        indicates that the default archiving  directory  (see  ›1m-a›22m)
  75.        should  be  used,  or  `-' which suppresses archiving.  An
  76.        explicit archiving directory (not `@') prefixed  with  `='
  77.        means that articles should be archived into that directory
  78.        itself; normally they go into subdirectories under  it  by
  79.        newsgroup  name,  as  in  the current­news directory tree.
  80.        (E.g., article 123 of comp.pc.drivel being  archived  into
  81.        archive    directory    ›4m/exp›24m    would    normally   become
  82.        ›4m/exp/comp/pc/drivel/123›24m, but if  the  archiving  directory
  83.        was  given  as `=/exp' rather than `/exp', it would become
  84.        ›4m/exp/123›24m.)  ›4mExpire›24m creates subdirectories under an archiv­
  85.        ing  directory  automatically,  but  will  not  create the
  86.        archiving directory itself.  Archiving directories must be
  87.        given as full pathnames.
  88.  
  89.        The  first  line  of  the  control file which applies to a
  90.        given article is used to control its  expiry.   It  is  an
  91.        error  for no line to apply; the last line should be some­
  92.        thing like `all x 7 -' to ensure that at least one line is
  93.        always  applicable.   Cross­posted articles are treated as
  94.        if they were independently posted to each group.
  95.  
  96.        The retention and purge  defaults  can  be  overridden  by
  97.        including  a ›4mbounds›24m line, one with the special first field
  98.        ›1m/bounds/›22m; the retention and purge defaults  for  following
  99.        lines  will be those of the bounds line.  The other fields
  100.        of a bounds line are ignored but must be present.
  101.  
  102.        Entries in the ›4mhistory›24m file can be retained after  article
  103.        expiry,  to  stop a late­arriving copy of the article from
  104.        being taken as a new article.  To arrange this, include  a
  105.        line  with  the  special  first field ›1m/expired/›22m; this line
  106.        then controls the expiry of ›4mhistory›24m lines after the corre­
  107.        sponding  articles  expire.  Dates are still measured from
  108.        article arrival, not expiry.  The other fields of  such  a
  109.        line are ignored but must be present.  It is strongly rec­
  110.        ommended that such a line be included, and that it specify
  111.        as long a time as practical.
  112.  
  113.        Command­line options are:
  114.  
  115.        ›1m-a›22m dir    ›4mdir›24m  is  the  default archiving directory; if no
  116.                  default is given, the control file may not  con­
  117.                  tain any `@' archive­directory fields.
  118.  
  119.        ›1m-p›22m        print an `index' line for each archived article,
  120.                  containing  its  pathname,  message   ID,   date
  121.                  received, and `Subject:' line.
  122.  
  123.        ›1m-s›22m        space is tight; optimize error recovery to mini­
  124.                  mize space consumed rather than to leave as much
  125.                  evidence as possible.
  126.  
  127.  
  128.  
  129.  
  130.                            28 Oct 1990                          2
  131.  
  132.  
  133.  
  134.  
  135.  
  136. EXPIRE(8)                                               EXPIRE(8)
  137.  
  138.  
  139.        ›1m-F›22m c      the  subfield  separator character in the middle
  140.                  ›4mhistory›24m field is ›4mc›24m rather than the normal `~'.
  141.  
  142.        ›1m-c›22m        check the format and consistency of the  control
  143.                  file  and  the  ›4mactive›24m  file,  but do not do any
  144.                  expiring.
  145.  
  146.        ›1m-n›22m nnnnn  set ›4mexpire›24m's idea of  the  time  to  ›4mnnnnn›24m  (for
  147.                  testing).
  148.  
  149.        ›1m-t›22m        print  (on  standard  error) a shell­script­like
  150.                  description of what would be done, but don't  do
  151.                  it.   In  the  absence  of archiving, all output
  152.                  lines will be of the form ``›1mremove›22m ›4mname›24m'', where
  153.                  ›4mname›24m  is a pathname relative to ›4m/usr/spool/news›24m.
  154.                  If an article is to be archived,  this  will  be
  155.                  preceded     (on     the     same    line)    by
  156.                  ``›1mcopy›22m ›4mname›24m ›4mdir›24m ›1m;›22m '', where ›4mname›24m is as in ›1mremove›22m
  157.                  and ›4mdir›24m is an archiving directory (including any
  158.                  `=' prefix) as specified by the control file  or
  159.                  the ›1m-a›22m option.
  160.  
  161.        ›1m-l›22m        consider  first filename in a ›4mhistory›24m line to be
  162.                  the ›4mleader›24m of its line, to be expired only after
  163.                  all  others  have  expired.   (Meant  for use on
  164.                  obnoxious systems like VMS which  don't  support
  165.                  real links.)
  166.  
  167.        ›1m-r›22m        suppress  ›4mhistory›24m  rebuild.  Mostly for emergen­
  168.                  cies.  (This leaves the ›4mhistory›24m file out of date
  169.                  and  larger  than  necessary, but improves speed
  170.                  and eliminates the need for several megabytes of
  171.                  temporary storage.)
  172.  
  173.        ›1m-h›22m        do   not  expire  any  article  which  would  be
  174.                  archived if it were expired.  Mostly  for  emer­
  175.                  gencies,  so  that  ›4mexpire›24m can be run (to delete
  176.                  articles in non­archived groups) even  if  space
  177.                  is short in archiving areas.
  178.  
  179.        ›1m-v›22m        verbose:  report  some statistics after termina­
  180.                  tion.
  181.  
  182.        ›1m-g›22m        report expiry dates  that  ›4mgetdate›24m(3)  does  not
  183.                  like.   ›4mExpire›24m  ignores such dates, treating the
  184.                  article as if it had no explicit expiry date.
  185.  
  186.        ›1m-d›22m        turn on (voluminous and cryptic) debugging  out­
  187.                  put.
  188.  
  189.        ›4mExpire›24m  considers  the  middle  field of a ›4mhistory›24m line to
  190.        consist of one or more subfields separated  by  `~'.   The
  191.        first  is  the  arrival  date,  which can be either a ›4mget­›24m
  192.        ›4mdate›24m(3)­readable date or a decimal seconds  count;  ›4mexpire›24m
  193.  
  194.  
  195.  
  196.                            28 Oct 1990                          3
  197.  
  198.  
  199.  
  200.  
  201.  
  202. EXPIRE(8)                                               EXPIRE(8)
  203.  
  204.  
  205.        leaves this field unchanged.  The second­­if present, non­
  206.        null, and not `-'­­is an  explicit  expiry  date  for  the
  207.        file, again in either format, which ›4mexpire›24m will convert to
  208.        a decimal seconds count  as  it  regenerates  the  ›4mhistory›24m
  209.        file.  Subsequent fields are preserved but ignored.
  210.  
  211.        ›4mDoexpire›24m  checks  whether  another  ›4mdoexpire›24m  is  running,
  212.        checks that there is enough  disk  space,  invokes  ›4mexpire›24m
  213.        with      any     ›4mexpireoptions›24m     given     and     with
  214.        ›4m/usr/lib/news/explist›24m as the control file, and reports any
  215.        difficulties  by  sending mail to ›4musenet›24m.  This is usually
  216.        better than just running ›4mexpire›24m directly.  If space is not
  217.        adequate  for archiving, ›4mdoexpire›24m reports this and invokes
  218.        ›4mexpire›24m with the ›1m-h›22m option.  If ›1m-r›22m is not among the ›4mexpire­›24m
  219.        ›4moptions›24m, and disk space is persistently inadequate for the
  220.        temporaries  needed  for  history   rebuilding,   ›4mdoexpire›24m
  221.        reports this and invokes ›4mexpire›24m with the ›1m-r›22m option anyway.
  222.  
  223.        ›4mMkhistory›24m rebuilds the ›4mhistory›24m file and its auxiliaries to
  224.        match  the articles in ›4m/usr/spool/news›24m.  ›4mUpact›24m updates the
  225.        third fields of the ›4mactive›24m file to match the  articles  in
  226.        ›4m/usr/spool/news›24m  (for  historical reasons, ›4mexpire›24m does not
  227.        do this).  ›4mRecovact›24m  updates  the  second  fields  of  the
  228.        ›4mactive›24m  file to match the articles in ›4m/usr/spool/news›24m, for
  229.        use in disaster recovery based on an outdated ›4mactive›24m file.
  230.        These  programs  are all fairly slow and they all lock the
  231.        whole news system for the duration of  the  run,  so  they
  232.        should not be run casually.
  233.  
  234. ›1mFILES›22m
  235.        /usr/lib/news/history   history file
  236.        /usr/lib/news/history.pag›4mdbm›24m database for history file
  237.        /usr/lib/news/history.dir›4mdbm›24m database for history file
  238.        /usr/lib/news/explist   expiry control file
  239.        /usr/lib/news/history.o history file as of last expiry
  240.        /usr/lib/news/history.n*new history file and ›4mdbm›24m files abuilding
  241.        /usr/lib/news/LOCKexpire›4mdoexpire›24m's lock file
  242.        /usr/lib/newsbin/expire/*various auxiliaries
  243.  
  244. ›1mSEE›22m ›1mALSO›22m
  245.        inews(1), dbm(3), relaynews(8)
  246.  
  247. ›1mHISTORY›22m
  248.        Written  at  U of Toronto by Henry Spencer, with contribu­
  249.        tions by Geoff Collyer.
  250.  
  251. ›1mBUGS›22m
  252.        Archiving is always done by  copying,  never  by  linking.
  253.        This  has  the  side effect that cross­posted articles are
  254.        archived as several independent copies.
  255.  
  256.        The ›1m-p›22m subject­finder botches continued header  lines,  as
  257.        does ›4mmkhistory›24m, although such lines are rare.
  258.  
  259.  
  260.  
  261.  
  262.                            28 Oct 1990                          4
  263.  
  264.  
  265.  
  266.  
  267.  
  268. EXPIRE(8)                                               EXPIRE(8)
  269.  
  270.  
  271.        ›4mUpact›24m  is  a distasteful kludge, but then, so is the third
  272.        field of the ›4mactive›24m file.
  273.  
  274.        ›4mUpact›24m forces the third field of the ›4mactive›24m file to  be  at
  275.        least  five digits, for backward compatibility, but other­
  276.        wise just makes it as  large  as  necessary.   The  group­
  277.        creation operations always create it ten digits long.  The
  278.        discrepancy is harmless, since unlike  the  second  field,
  279.        the third field is never updated in place.
  280.  
  281.        One  cannot  put  more  than  one  newsgroup into a single
  282.        archiving directory with the `=' feature, since the  arti­
  283.        cle  numbers  will  collide  with  each  other  and expire
  284.        doesn't do anything about this.   Note  that  archiving  a
  285.        newsgroup  which  has subgroups into an `=' directory puts
  286.        all the subgroups in the same  directory  as  the  parent!
  287.        (Specifying the group as `foo.bar,!foo.bar.all' will avoid
  288.        this.)
  289.  
  290.        ›4mMkhistory›24m is inherently incapable of  reconstructing  his­
  291.        tory­file  lines  corresponding to expired articles.  Pro­
  292.        tection against old articles reappearing is thus  somewhat
  293.        limited for a while after the history file is rebuilt.
  294.  
  295.        ›4mExpire›24m  uses ›4maccess›24m(2) to test for the presence of archiv­
  296.        ing directories, which can cause anomalies if  it  is  run
  297.        setuid (normally it's not).
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.                            28 Oct 1990                          5
  329.  
  330.  
  331.